function initMenuAction(){
    var navMenuContainer = document.getElementById("nav");
	var navMenus = navMenuContainer.getElementsByTagName('a');
    for (var i = 0; i < navMenus.length; i++) {
        navMenus[i].addEventListener('click', function(e){
            $(this).parent().addClass('active');
			for(var j=0;j<navMenus.length;j++){
				if(navMenus[j]!=this){
					$(navMenus[j]).parent().removeClass('active');
				}
			}
        }, 'false');
    }
}
$(document).ready(initMenuAction);
